<?xml version='1.0' encoding='utf-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:c="http://java.sun.com/jsp/jstl/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:a4j="http://richfaces.org/a4j"
	xmlns:rich="http://richfaces.org/rich">

<ui:composition template="../commun_page/template.xhtml">

	<ui:define name="title">
		<title>Identification</title>
	</ui:define>

	<ui:define name="body">


		<h1>Identification</h1>


		<h:form>
			<rich:panel style="margin-left:50px; width: 500px;">
				<f:facet name="header">
					<h:panelGroup>
						<h:outputText value="Formulaire d'identification" />
					</h:panelGroup>
				</f:facet>
				<h:panelGrid columns="3">

					<h:outputText value="Identifiant" />
					<h:inputText value="#{manager.client.login}" id="login">
						<a4j:ajax event="keyup" render="out_login" />
					</h:inputText>
					<rich:message id="out_login" for="login" />
					
					<h:outputText value="Password" />
					<h:inputSecret value="#{manager.client.password}" id="password">
						<a4j:ajax event="keyup" render="out_password" />
					</h:inputSecret>
					<rich:message id="out_password" for="password" />

					<h:outputText value="" />
					<h:commandButton value="Valider" action="#{manager.loginAction}" />
					<h:outputText value="" />

					<h:outputText value="" />
					<h:panelGroup id="out_err" >
						<c:if test="${manager.messagesErrSize > 0}">
							<c:set var="mess" scope="request" value="#{manager.messagesErr}"></c:set>
							<ul class="err">
								<c:forEach items="#{mess}" var="s">
									<li> <h:outputText value="#{s}" /></li>
								</c:forEach>
							</ul>
						</c:if>
					</h:panelGroup>
					<h:outputText value="" />

				</h:panelGrid>
			</rich:panel>
		</h:form>


	</ui:define>

</ui:composition>

</html>
